package com.ujiuye.dao;

import com.ujiuye.util.DruidUtils;
import org.apache.commons.dbutils.QueryLoader;
import org.apache.commons.dbutils.QueryRunner;

import java.sql.SQLException;

public class DeleteDao {
    public int dd(String id){
        QueryRunner qr = new QueryRunner(DruidUtils.getDataSource());
        String sql="delete from user where Uid=?";
        int row=0;
        try {
            row = qr.update(sql, id);
        } catch (SQLException e) {
            e.printStackTrace();
        }
        return row;
    }
}
